
<?php
//MAIN FORM CLASS. ALWAYS BEING USED, INDIRECTLY.
/**
 * Registration Form
 * This form would allow users of the system register with the system
 *
 */

 class Student_Form_NewAssessment extends Zend_Dojo_Form
 {
	public function __construct($options = null)
		{
		parent::__construct($options);
		Zend_Dojo::enableForm($this);
		$this->setName('NewCourse');
		//$id = new Zend_Form_Element_Hidden('id');

		//User enters his First Name
		 $Noptions = (array ("Homeworks" => "Homework",
					"Quizzes" => "Quiz",
					"Projects" => "Project",
					"Lab" => "Lab",
					"Midterm" => "Midterm Exams",
                                        "Final" => "Final Exam",
                                          "Other" => "Other"
					));
            $assessment = new Zend_Dojo_Form_Element_ComboBox('assess_name');
            $assessment->setLabel('Assessment group:');
            $assessment->addMultiOptions($Noptions);
            $assessment->setAutocomplete(true);

                $assessment_weight = new Zend_Dojo_Form_Element_ValidationTextBox('assess_weight');
		$assessment_weight->setLabel('How much is this group worth?')
		->setRequired(true)
		->addFilter('StripTags')
		->addFilter('StringTrim')
                ->addFilter('StringToUpper')
		->addValidator('NotEmpty');


                $Aoptions = (array ("0" => "0",
					"1" => "1",
					"2" => "2",
					"3" => "3",
					"4" => "4",
                                        "5" => "5",
                                        "6" => "6",
                                        "7" => "7",
                                        "8" => "8",
                                        "9" => "9",
                                        "10" => "10",
                                          
					));
            $assignment = new Zend_Dojo_Form_Element_ComboBox('num_of_assign');
            $assignment->setLabel('Number of assignments in this group:');
            $assignment->addMultiOptions($Aoptions);
            $assignment->setAutocomplete(true);







		$submit = new Zend_Dojo_Form_Element_SubmitButton('submit');

		$this->addElements(array($assessment, $assessment_weight, $assignment));
	    $this->addElement($submit);
		//$this->setAction('register');
		$this->setMethod('POST');
		}
}



